package com.huilink.webmail.util.client;

import com.google.gwt.user.client.ui.Grid;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.Panel;
import com.google.gwt.user.client.ui.TextBoxBase;
import com.google.gwt.user.client.ui.Widget;
import com.huilink.webmail.util.client.widgets.InputPanel;

/**
 */
public class WidgetManagerImpl implements WidgetManager
{
    public void addTextBoxToGrid(Grid grid, int row, int column, TextBoxBase textBox){
        grid.setWidget(row,column,textBox);
    }

	public void removeFromParent(Widget widget) {
		widget.removeFromParent();
	}

	public void addLabel(Panel panel, Label label) {
		panel.add(label);
	}

	public void addTextBoxToPanel(Panel panel, TextBoxBase textBox) {
		panel.add(textBox);
	}

	public void addInputPanel(Panel panel, InputPanel input) {
		panel.add(input);
	}

	public void addWidgetToPanel(Panel panel, Widget widget) {
		panel.add(widget);
		
	}
}
